# $Id$
# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Justin Davis (juster) <jrcd83@gmail.com>

pkgname=perl-async-interrupt
pkgver=1.24
pkgrel=2
pkgdesc='allow C/XS libraries to interrupt perl asynchronously'
arch=(x86_64)
license=(PerlArtistic GPL)
options=(!emptydirs)
depends=('perl-canary-stability' 'perl-common-sense')
url=https://metacpan.org/release/Async-Interrupt
source=("http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/Async-Interrupt-$pkgver.tar.gz")
sha512sums=('7632d0537e2f7dd6fb406333ced170261eb5de2b5db86f066fac61ba37a6d7995a72de4cb9c329e2d93369dc591cce5e1b8baef5976e13b58c42411e930ac246')

build() {
  cd Async-Interrupt-$pkgver
  PERL_MM_USE_DEFAULT=1 perl Makefile.PL
  make
}

check() {
  cd Async-Interrupt-$pkgver
  make test
}

package() {
  cd Async-Interrupt-$pkgver
  make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
  find "$pkgdir" -name .packlist -o -name perllocal.pod -delete
}
